import React from 'react'
import { Router, Route, Switch, Redirect } from 'dva/router'
import Home from './pages/Home'
import HomeList from './pages/HomeList'
import Sign from './pages/Sign'
// const Home = () => <h1>欢迎回来，方羽！</h1>
let fn = function ({ history }) {
  return (
    <Router history={history}>
      <Switch>
        <Route path = '/' exact component = { Sign } />
        <Route path = '/sign' component = { Sign } />
        <Route path = '/home/list' component = { HomeList } />
        <Route path = '/home' component = { Home } />
        <Redirect to = '/' />
      </Switch>
    </Router>
  )
}
export default fn